package com.zenithmind.library.pojo.query;

import com.zenithmind.common.query.BaseQuery;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDate;

/**
 * 图书评价查询条件
 *
 * @author ZenithMind
 * @since 2024-06-14
 */
@EqualsAndHashCode(callSuper = true)
@Data
@Schema(name = "图书评价查询条件", description = "图书评价查询的条件参数")
public class BookReviewQuery extends BaseQuery {

    @Schema(description = "用户ID", example = "1")
    private String userId;

    @Schema(description = "用户姓名", example = "张三")
    private String userName;

    @Schema(description = "图书ID", example = "1")
    private String bookId;

    @Schema(description = "图书标题", example = "Java编程思想")
    private String bookTitle;

    @Schema(description = "图书ISBN", example = "9787111213826")
    private String bookIsbn;

    @Schema(description = "评分", example = "5")
    private Integer rating;

    @Schema(description = "最小评分", example = "1")
    private Integer minRating;

    @Schema(description = "最大评分", example = "5")
    private Integer maxRating;

    @Schema(description = "是否匿名 (0-否, 1-是)", example = "0")
    private Integer isAnonymous;

    @Schema(description = "状态 (0-隐藏, 1-显示)", example = "1")
    private Integer status;

    @Schema(description = "最小点赞数", example = "0")
    private Integer minLikeCount;

    @Schema(description = "最大点赞数", example = "100")
    private Integer maxLikeCount;

    @Schema(description = "评价内容关键词", example = "推荐")
    private String contentKeyword;

    @Schema(description = "创建开始日期", example = "2024-01-01")
    private LocalDate createStartDate;

    @Schema(description = "创建结束日期", example = "2024-12-31")
    private LocalDate createEndDate;

    @Schema(description = "排序字段", example = "createTime")
    private String sortField;

    @Schema(description = "排序方向 (asc/desc)", example = "desc")
    private String sortOrder;
}
